package com.ysstech.schedule;

import com.alibaba.druid.spring.boot.autoconfigure.DruidDataSourceAutoConfigure;
import com.ysstech.common.util.SpringContextUtil;
import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.web.servlet.MultipartAutoConfiguration;
import org.springframework.cloud.client.circuitbreaker.EnableCircuitBreaker;
import org.springframework.context.ApplicationContext;

/**
 * 定时任务启动类,扫描有定时任务模块
 */
@MapperScan({"com.ysstech.schedule.mapper", "com.ysstech.common.mapper"})
@EnableCircuitBreaker
@SpringBootApplication(scanBasePackages = {"com.ysstech.system", "com.ysstech.schedule",
        "com.ysstech.finance", "com.ysstech.etfmanage", "com.ysstech.valuation","com.ysstech.reportworld"}
        , exclude = {MultipartAutoConfiguration.class, DruidDataSourceAutoConfigure.class})
public class ScheduleApplication {
    public static void main(String[] args) {
        ApplicationContext applicationContext = SpringApplication.run(ScheduleApplication.class, args);
        new SpringContextUtil().setApplicationContext(applicationContext);
    }
}
